package com.dong.auth.module.oauth2.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.sql.Blob;
import java.util.Date;

import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 授权码Code记录表
 * </p>
 *
 * @author zhao dong chao
 * @since 2021-09-03 53:12:32
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("oauth_code")
public class OauthCode implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 存储服务端系统生成的code的值(未加密)
     */
    @TableId(type= IdType.INPUT)
    private String code;
    /**
     * AuthorizationRequestHolder.java对象序列化内容
     */
    private Blob authentication;

    @TableField("create_time")
    private Date createTime;
}
